package com.spring.demo5;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;

@Configuration
public class ConfigA {
	@Scope("prototype")//多实例注释默认单例
	@Bean(initMethod = "init", destroyMethod = "cleanup" )
	public A a(){
		return new A();
	}
}
